<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtm1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>欢迎登录后台管理系统</title>
<link rel="shortcut icon" type="text/css" href="../images/favicon.ico"/>
<link href="css/login.css" rel="stylesheet" type="text/css" />
<script src="../login_admin/js/jquery-1.11.3.min.js"></script>
<script >
	function login_Admin(){
		var username=$("#username").val();
		var password=$("#password").val();
		if(username==""||password==""){
			alert("用户名或者名字不能为空");
		}else{
			$.ajax({
				url:"../json/AdminAction_LoginAdmin",
				dataType:"json",
				type:"post",
				data:$("#login_form").serialize(),
				success:function(data){
					console.info(data);
					if(data.result==1){
						location.href="../back/index.jsp";
					}else {
						alert("请查看用户名/密码是否正确");
					}
				}
			});
		}
	}
</script>

</head>

<body>
<div class="main-login">
	<div class="login-content">	
	<h2>用户登录</h2>
	
    <form id="login_form" method="post" id="login-form" name="login-form">
	    <div class="login-info">
			<span class="user">&nbsp;</span>
			<input name="aname" id="username" type="text"  value="张二" class="login-input"/>
		</div>
	    <div class="login-info">
			<span class="pwd">&nbsp;</span>
			<input name="apwd" id="password" type="password"  value="111" class="login-input"/>
		</div>
	    <div class="login-oper">
			<input name="" style="margin:1px 10px 0px 2px; float:left;" name="" type="checkbox" value="" checked="checked" /><span>记住密码</span>
		</div>
	    <div class="login-oper">
			<input name="" type="button" value="登 录" class="login-btn" onclick="login_Admin()"/>
			<input name="" type="submit" value="重 置" class="login-reset"/>
		</div>
    </form>
    </div>
</div>   

<div style="text-align:center;">
	<a href="../to_index.jsp" style="font-size:20px;">改变，从心开始</a>
</div>

</body>

</html>
